{include file="Include/H_ui_head" /}
<nav class="breadcrumb"><i class="Hui-iconfont">&#xe67f;</i>  <a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" ><i class="Hui-iconfont">&#xe68f;</i></a></nav>
<div class="page-container">
    <div class="cl pd-5 bg-1 bk-gray mt-20"> <span class="l">
        <input class="btn btn-danger radius"  type="submit" onclick="datadel('{:Url('platform/commonProblem_delAll')}')" value="批量删除" name="sub">
        <!--<a href="javascript:;" onclick="member_add('编辑问题','{:Url('platform/add')}','','510')" class="btn btn-primary radius">
        <i class="Hui-iconfont">&#xe600;</i> 编辑问题</a>-->
        </span>
        <!--<span class="r">共有数据：<strong>{}</strong> 条</span>-->
    </div>
    <div class="mt-20">
        <table class="table table-border table-bordered table-hover table-bg ">
            <thead>
            <tr class="text-c">
                <th width="25"><input type="checkbox" name="" value=""></th>
                <th width="70">序号</th>
                <th width="100">留言类型</th>
                <th width="100">留言内容</th>
                <th width="100">回复内容</th>
                <th width="100">留言时间</th>
                <th width="100">状态</th>
                <th width="100">操作</th>
            </tr>
            </thead>
            <tbody>
            {volist name="rs" id="val" key="k"}
            <tr class="text-c">
                <td><input type="checkbox" value="{$val.id}" name="checkbox[]"></td>
                <td>{$k}</td>
                <td>{$val.advisory_name}</td>
                <td>{$val.question}</td>
                <td>{$val.answer}</td>
                <td>{$val.create_time}</td>
                <td>
                {if $val.status == 0}
                    未回复
                    {elseif $val.status == 1}
                    已回复
                    {else}
                    用户删除
                    {/if}
                </td>
                <td class="td-manage">
                    {if $val.status != 1}
                    <a title="回复" href="javascript:;" onclick="member_edit('回复','{:Url('platform/commonProblem_edit',['id'=>$val['id']])}','4','','510')" class="ml-5" style="text-decoration:none">
                        回复</a>
                    {/if}
                    <a title="删除" href="javascript:;" onclick="member_del(this,'{:Url('platform/commonProblem_del')}','{$val.id}')" class="ml-5" style="text-decoration:none">
                        删除</a>
                </td>
            </tr>
            {/volist}
            </tbody>
        </table>
        <div style="float: right">{$page}</div>
    </div>
</div>
{include file="Include/H_ui_foot" /}
<!--请在下方写此页面业务相关的脚本-->
<script type="text/javascript" src="__LIB__/My97DatePicker/4.8/WdatePicker.js"></script>
<script type="text/javascript">
    /*问题-添加*/
    function member_add(title,url,w,h){
        layer_show(title,url,w,h);
    }
    /*问题-修改*/
    function member_edit(title,url,id,w,h){
        layer_show(title,url,w,h);
    }
    /*问题-删除*/
    function member_del(obj,url,id){
        delOne(obj,url,id);
    }
    /*问题-批量删除*/
    function datadel(url) {
        var obj = document.getElementsByName("checkbox[]");
        var check_val = [];
        for(k in obj){
            if(obj[k].checked)
                check_val.push(obj[k].value);
        }
        delAll(url,obj,check_val);
    }
</script>
</body>
</html>
